import Vue from 'vue'
import Router from 'vue-router'
Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'login', //登录界面
      component: () => import('@/components/common/login'),
    },
    {
      path:'/register',
      component:()=>import('@/components/common/register')
    },
    {
      path: '/index', //用户主页
      component: () => import('@/components/student/index'),
      children: [
        {
          path: '/', //首页默认路由
          component: () => import('@/components/common/hello')
        },
        {
          path: '/Directions', //就业信息登记
          component: () => import('@/components/student/Directions')
        },
        {
          path: '/ApplyRecord', //岗位申请
          component: () => import('@/components/student/ApplyRecord')
        },
        {
          path: '/careerTalk', //宣讲会
          component: () => import('@/components/student/careerTalk')
        },
        {
          path: '/career', //招聘会
          component: () => import('@/components/student/career')
        },
        {
          path: '/PersonalManage', //个人信息管理界面
          component: () => import('@/components/student/PersonalManage')
        },
        {
          path: '/updateInfo', //修改个人信息
          component: () => import('@/components/student/updateInfo')
        },
        {
          path: '/updatePwd', //修改密码
          component: () => import('@/components/student/updatePwd')
        },
        {
          path: '/careerTest',//职业测评
          component: () => import('@/components/student/careerTest')
        },
      ]
    },
    {
      path: '/admin',
      component: () => import('@/components/admin/index'),
      children: [
        {
          path: '/employmentRate',//就业率比较
          component: () => import('@/components/admin/employmentRate')
        },
        {
          path: '/userManage',//个人信息管理
          component: () => import('@/components/admin/userManage')
        },
        {
          path: '/careerInfo',//就业信息管理
          component: () => import('@/components/admin/careerInfo')
        },
        {
          path: '/careerTalkManage',//宣讲会管理
          component: () => import('@/components/admin/careerTalkManage')
        },
        {
          path: '/interviewManage',//招聘会管理
          component: () => import('@/components/admin/interviewManage')
        },
        {
          path: '/compare',//历年数据对比
          component: () => import('@/components/admin/compare')
        }
      ]
    },

  ]
})
